﻿using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class team_webcon_nav : System.Web.UI.UserControl
{
    Team tea;
    protected void Page_Load(object sender, EventArgs e)
    {
        tea = Team.Check();
        if (tea == null)
        {
            Session.Add(Params.SystemError, "请先登录");
            Response.Redirect(Params.RootHttp + "default.aspx");
        }
        if (tea.Email == "" && !Fun.IsProfilePage() && !Page.IsPostBack)
        {
            Fun.Redirect(Params.TeamFolderHttp + "profile.aspx?uid="+Request.Params["uid"], "请完整个人信息！");
        }
        int n = tea.NotReadYeatNum;
        if (n > 0)
        {
            this.hlRecv.Text = "收件箱（" + n.ToString() + "）";
            this.hlRecv.Font.Bold = true;
        }
        string info = "共有导师" + this.tea.DoctorNum.ToString() + "名，学生" + this.tea.StudentNum.ToString() + "名，审阅论文" + this.tea.PaperCount.ToString() + "篇，其中通过" + this.tea.PastPaperCount.ToString() + "篇，在审" + this.tea.SuspendPaperCount.ToString() + "篇，打回" + this.tea.FailPaperCount.ToString() + "篇";
        this.PageHeader = info;
        this.hlRecv.NavigateUrl = Params.TeamFolderHttp + "recv.aspx?uid=" + Request.Params["uid"];
    }

    public string Title
    {
        set
        {
            this.hTitle.InnerText = value;
        }
    }

    public string PageHeader
    {
        set
        {
            this.divHeader.InnerText = value;
        }
    }
}
